package HomeWork;
public class HomeWork02 {

	public static void main(String[] args) {
		double discount = 1;
		int totalprice = 550;

		if(totalprice >= 500){
			discount = 0.5;
		}else if(totalprice >= 400 && totalprice < 500){
			discount = 0.6;
		}else if(totalprice >= 300 && totalprice < 400){
			discount = 0.7;
		}else if(totalprice >= 200 && totalprice < 300){
			discount = 0.8;
		}
		System.out.println("totalprice:"+totalprice);
		System.out.println("totalprice乘以"+"discount:"+ (totalprice*discount) );
	}

}
